<%@page import="business.Obat"%>
<%@page import="business.ObatListing"%>
<%@page import="business.ObatOrder"%>
<%@page import="business.ObatSubject"%>
<%@page import="java.util.Iterator"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
   "http://www.w3.org/TR/html4/loose.dtd">

<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Daftar Obat</title>
    </head>
    <body>
        <h1>Daftar Obat</h1>
        <a href ="logout">Logout</a>
        <a href ="ubahAkun">Mengubah Akun</a>

        <a href ="daftarObat">Daftar Obat</a>
        <table border="1">
            <thead>
                <tr>
                    <th>Merk</th>
                    <th>Deskripsi</th>
                </tr>
            </thead>
            <tbody>
                <%
                Iterator<Obat> i = (Iterator<Obat>) request.getAttribute("merk");
                int no = 0;
                while(i.hasNext()){
                    Obat ob = i.next();

                    no++;
                %>

                <tr>
                    <td><%=(no)%></td>
                    <td><%=(ob.getDeskripsi())%></td>
                    <td><a href="detailObat">Lihat detail</a></td>
                    <td><a href="order">Order obat</a></td>
                </tr>
                <%
                }
                %>
            </tbody>
        </table>
    </body>

</html>